/******************************************************************************/
/*!
\file   System.hpp
\author David Seah Seng Chong
\par    email: ssc1987@gmail.com
\date 26/12/2011
\brief
    Header file
    System Header

      Functions included in file:\n

    Copyright (C) 2011 
	Reproduction or disclosure of this file or its contents without the
    prior written consent is prohibited.
*/
/******************************************************************************/
#ifndef SYSTEM_HPP
#define SYSTEM_HPP

#define CSYSTEM			ReekEngine::CSystem::GetSingleton()
#define DELETE_CSYSTEM	ReekEngine::CSystem::DeleteSingleton()

namespace ReekEngine
{
class CWindow;

class CSystem
{
public:
	static CSystem * GetSingleton();
	static void DeleteSingleton();
		
	bool Initialize();
	void Update();
	void Shutdown();

	signed int GetWindowWidth() const { return m_WindowWidth; }
	signed int GetWindowHeight() const { return m_WindowHeight; }
	
	void SetWindowWidth(signed int width) { m_WindowWidth = width; }
	void SetWindowHeight(signed int height) { m_WindowHeight = height; }
    
	float GetAspectRatio() const { return float(m_WindowWidth) / m_WindowHeight; }

	bool IsGameActive() const { return m_GameActive; }
	void EndGame() { m_GameActive = false; }
    
private:
	// Singleton Design
	CSystem() {} 
	~CSystem(){}

	CWindow * m_Window;

	signed int m_WindowWidth;
	signed int m_WindowHeight;

	bool m_GameActive;
	static CSystem * m_Singleton;
};

}

#endif